package club.vann.kafka.mock.common.config;

import lombok.Data;
import org.springframework.beans.factory.InitializingBean;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Configuration;

@Data
@Configuration
public class AppConfig implements InitializingBean {
  public static AppConfig config;

  @Value("${zhongyong.base-url:#{null}}")
  private String zhongyongBaseUrl;

  @Value("${spring.kafka.prefix:#{null}}")
  private String kafkaTopicPrefix;

  @Override
  public void afterPropertiesSet() {
    AppConfig.config = this;
  }
}
